<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

<html>
<head>
	<title>Insert Link</title>
	<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<style type="text/css">
#linkTable {
	border: 1px solid black ;
	margin-right: auto;
	margin-left: auto;
}
.linkTableCell {
	font: bold 0.9em Verdana, Arial, Sans-Serif;
	text-align: right;
}
.linkTableCellTop {
	font: 0.8em Verdana, Arial, Sans-Serif;
	text-align: left;
}
</style>
<script language="JavaScript" type="text/javascript">
<!--
function AddLink() {
	var oForm = document.linkForm;
//validate form
	if (oForm.url.value == '') {
		alert('Please enter a url.');
		return false;
	}
	if (oForm.linkText.value == '') {
		alert('Please enter link text.');
		return false;
	}
	
	var html = '<a href="' + document.linkForm.url.value + '">' + document.linkForm.linkText.value + '</a>';
	
	window.opener.insertHTML(html);
	window.close();
	return true;
}
//-->
</script>
</head>

<body>

<form name="linkForm" onSubmit="return AddLink();">
<table cellpadding="4" cellspacing="0" border="0" id="linkTable">
	<tr><td colspan="2" class='linkTableCellTop'><b>Tip:</b> To insert an email link, start your URL with "mailto:"</td></tr>
	<tr>
		<td align="right" class='linkTableCell'>URL:</td>
		<td class='linkTableCell'><input name="url" type="text" id="url" size="40"></td>
	</tr>
	<tr>
		<td align="right" class='linkTableCell'>Text:</td>
		<td class='linkTableCell'><input name="linkText" type="text" id="linkText" size="40"></td>
	</tr>
	<tr>
		<td colspan="3" align="center" class='linkTableCell'>
			<input type="submit" value="Insert Link" />
			<input type="button" value="Cancel" onClick="window.close();" />
		</td>
	</tr>
</table>

</form>

</body>
</html>
